<template>
  <div class="demoBox">
    <div class="demo1">
      <div v-permission="['red']" @click="clickDIV()"><span>有权限</span></div>
    </div>
    <div class="demo1">
      <div v-permission="['blue']" @click="clickDIV()"><span>有权限</span></div>
    </div>
    <div class="demo1">
      <div v-permission="['red','blue']" @click="clickDIV()"><span>有权限</span></div>
    </div>
    <div class="demo1">
      <div v-permission="['red','yellow']" @click="clickDIV()"><span>有权限</span></div>
    </div>
    <div class="demo1">
      <div v-permission="['yellow']" @click="clickDIV()"><span>无权限</span></div>
    </div>

  </div>
</template>

<script>
export default {
  data() {
    return {};
  },
  methods: {
    clickDIV(){
        alert("我是有权限的！！！！！")
    }
  },
};
</script>

<style >
.demoBox {
  background: rgb(26, 127, 199);
  height: 940px;
  width: 1920px;
}
.demo1 {
  height: 200px;
  width: 300px;
  background: rgb(88, 239, 156);
  float: left;
  margin: 20px;
  color: aliceblue;
  font-size: 70px;
  text-align: center;
  cursor: pointer;
}
</style>